EL PASO, Texas (AP) — The gunman who killed 23 people in a racist attack at a Texas Walmart — one of the deadliest mass shootings in U.S. history — is expected to accept a plea deal in a state court on Monday to avoid the death penalty.

Patrick Crusius has acknowledged he targeted Hispanics on Aug. 3, 2019, when he opened fire in the store crowded with weekend shoppers from the U.S. and Mexico in the border city of El Paso.

Under the offer, Crusius would plead guilty to capital murder and receive life in prison with no possibility of parole, El Paso County District Attorney James Montoya has said.

Texas prosecutors declined to pursue the death penalty. Montoya says the decision was driven by a majority of victims’ relatives who want the case to be over.

Crusius already has been sentenced to 90 consecutive life terms at the federal level after pleading guilty to hate crimes and weapons charges.

If the plea arrangement proceeds, families will be able to give victim impact statements. Dozens of people made emotional statements during a similar hearing in federal court in 2023 that lasted three days.

Crusius, a white community-college dropout, was 21 years old when police say he drove more than 700 miles (1,100 kilometers) to El Paso from his home near Dallas.

Not long after posting a racist rant online warning of a Hispanic "invasion," he opened fire with an AK-style rifle inside and outside the store. Police arrested Crusius shortly after.

Joe Spencer, a defense attorney in the state and federal cases, said Crusius was diagnosed with schizoaffective disorder that can be marked by hallucinations, delusions and mood swings and has suffered from debilitating mental illness for most of his life.

“You are talking about an individual with a broken brain,” he said Thursday.

The people killed at Walmart ranged in age from a 15-year-old high school athlete to elderly grandparents. They included immigrants, a retired city bus driver, a teacher, tradesmen including a former iron worker and several Mexican nationals who crossed the U.S. border on routine shopping trips.

___

Stengle contributed to this story from Dallas.

FILE - In this Thursday, May 21, 2020 photo, Vanessa Romero holds her son at a memorial service for the 23rd victim of the Aug. 3 Walmart shooting while wearing an "El Paso Strong" T-shirt and a face mask in El Paso, Texas. AP Photo/Cedar Attanasio, File)

Credit: AP

icon to expand image

Credit: AP

FILE - A woman is reflected in a picture as she looks at a makeshift memorial at the scene of a mass shooting at a shopping complex Tuesday, Aug. 6, 2019, in El Paso, Texas. (AP Photo/John Locher, File)

Credit: AP

icon to expand image

Credit: AP

FILE - In this Aug. 12, 2019 photo, mourners visit the makeshift memorial near the Walmart in El Paso, Texas. (AP Photo/Cedar Attanasio, File)

Credit: AP

icon to expand image

Credit: AP

FILE - Eddie Medina, 62, carries groceries he bought for his wife at the reopening of the Cielo Vista Walmart, Thursday, Nov. 14, 2019, in El Paso, Texas. (AP Photo/Cedar Attanasio, File)

Credit: AP

icon to expand image

Credit: AP